package hngc.com;

import java.util.Scanner;

public class Box16 {
    public static void main(String[] args) {
        String username;
        String password;
        Scanner scanner=new Scanner(System.in);
        System.out.println("输入用户名");
        username=scanner.nextLine();
        System.out.println("输入密码");
        password=scanner.nextLine();
        if (username.isEmpty()&&password.isEmpty()){
        }else if(username.equals("admin")&&password.equals("123")){
            System.out.println("登录成功");
        }else if(!(username.equals("admin"))&&password.equals("123")){
            System.out.println("请输入正确的用户名");
        }else if(username.equals("admin")&&!(password.equals("123"))){
            System.out.println("请输入正确的密码");
        }else if(!(username.equals("admin"))&&!(password.equals("123"))){
            System.out.println("请输入正确的用户名和密码");
        }
        scanner.close();
    }
}
